import xadmin
from operation.models import UserAsk, UserLove, UserCourse, UserComment, UserMessage, UserTrusteeship, UserFood


class UserAskXadmin(object):
    list_display = ['name', 'phone', 'course', 'add_time']
    model_icon = 'fa fa-user-circle-o'


# 用户收藏表
class UserLoveXadmin(object):
    list_display = ['love_man', 'love_id', 'love_category', 'love_status', 'add_time']
    model_icon = 'fa fa-heart'


# 用户的学习课程表
class UserCourseXadmin(object):
    list_display = ['study_man', 'study_course', 'study_every', 'add_time']
    model_icon = 'fa fa-suitcase'


# 用户评论表
class UserCommentXadmin(object):
    list_display = ['comment_man', 'comment_course', 'comment_food', 'comment_content']
    model_icon = 'fa fa-comment'


# 用户的消息表
class UserMessageXadmin(object):
    list_display = ['message_man', 'message_content', 'message_status']
    model_icon = 'fa fa-commenting'


# 用户的托管信息
class UserTrusteeshipXadmin(object):
    list_display = ['user_trusteeship', 'type', 'trusteeship_everyday', 'trusteeship_everyday', 'teacher_feedback',
                    'add_time']
    model_icon = 'fa fa-male'


# 用户的饮食表
class UserFoodXadmin(object):
    list_display = ['user_food_name', 'food_info','add_time']
    model_icon = 'fa fa-male'


xadmin.site.register(UserAsk, UserAskXadmin)
xadmin.site.register(UserLove, UserLoveXadmin)
xadmin.site.register(UserCourse, UserCourseXadmin)
xadmin.site.register(UserComment, UserCommentXadmin)
xadmin.site.register(UserFood, UserFoodXadmin)
xadmin.site.register(UserMessage, UserMessageXadmin)
xadmin.site.register(UserTrusteeship, UserTrusteeshipXadmin)
